#!/bin/sh

SYSLOG_CONF=/etc/syslog.conf
NEWSYSLOG_CONF=/etc/newsyslog.conf

if [ "$2" = "POST-DEINSTALL" ]; then
echo -n "Cleaning up ${SYSLOG_CONF}..."
if [ -f ${SYSLOG_CONF} ]; then
  sed -e "/# Begin CS sudo log/,/# End CS sudo log/d" -i "" ${SYSLOG_CONF}
fi
echo "Done."
echo -n "Cleaning up ${NEWSYSLOG_CONF}..."
if [ -f ${NEWSYSLOG_CONF} ]; then
  sed -e "/# Begin CS sudo log/,/# End CS sudo log/d" -i "" ${NEWSYSLOG_CONF}
fi
echo "Done."
fi
